ASP.NET Core: Cloud-ready, Enterprise Web Application Development by Ragupathi Mugilan T. S. & Sanctis Valerio De & Singleton James
Author:Ragupathi, Mugilan T. S. & Sanctis, Valerio De & Singleton, James [Ragupathi, Mugilan T. S.]
Language: eng
Format: azw3
Publisher: Packt Publishing
Published: 2017-06-09T04:00:00+00:00
Item Detail View
When we split our Item Detail View into two distinctive components (View mode and Edit mode), we also gave them a minimalistic, wiki-like tabbed interface. Now that we have Bootstrap we can further improve that approach by redesigning it into a more intuitive, visually engaging view-editor interface.
Display mode
Open the /Scripts/app/item-detail-view.component.ts and remove the @Component's styles section entirely. We won't need it anymore, as we'll be using our style.less file from now on.
Right after that, replace the template section HTML content with the following code:
<div *ngIf="item"> <h2> <a href="#" (click)="onBack()">« Back to Home</a> </h2> <div class="item-container"> <ul class="nav nav-tabs"> <li role="presentation"> <a href="#" (click)="onItemDetailEdit(item)">Edit</a> </li> <li role="presentation" class="active"> <a href="#">View</a> </li> </ul> <div class="panel panel-default"> <div class="panel-body"> <div class="item-image-panel"> <img src="/img/item-image-sample.png" alt="{{item.Title}}" /> <div class="caption">Sample image with caption.</div> </div> <h3>{{item.Title}}</h3> <p>{{item.Description}}</p> <p>{{item.Text}}</p> </div> </div> </div> </div>
There's a couple of things worth noting here:
We added a second <p> element to display the item.Text property
We don't support item image files yet, so we added a demo image to see how it might look
We added a reference to an onBack() method to allow the user to navigate back to the Welcome View without having to resort to the navigation menu
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
The Mikado Method by Ola Ellnestam Daniel Brolund(25294)
Hello! Python by Anthony Briggs(24339)
Secrets of the JavaScript Ninja by John Resig Bear Bibeault(23433)
Kotlin in Action by Dmitry Jemerov(22512)
The Well-Grounded Java Developer by Benjamin J. Evans Martijn Verburg(21976)
Dependency Injection in .NET by Mark Seemann(21847)
OCA Java SE 8 Programmer I Certification Guide by Mala Gupta(20711)
Algorithms of the Intelligent Web by Haralambos Marmanis;Dmitry Babenko(19523)
Grails in Action by Glen Smith Peter Ledbrook(18607)
Adobe Camera Raw For Digital Photographers Only by Rob Sheppard(17034)
Sass and Compass in Action by Wynn Netherland Nathan Weizenbaum Chris Eppstein Brandon Mathis(15843)
Secrets of the JavaScript Ninja by John Resig & Bear Bibeault(13690)
Test-Driven iOS Development with Swift 4 by Dominik Hauser(11857)
Jquery UI in Action : Master the concepts Of Jquery UI: A Step By Step Approach by ANMOL GOYAL(11151)
A Developer's Guide to Building Resilient Cloud Applications with Azure by Hamida Rebai Trabelsi(10621)
Hit Refresh by Satya Nadella(9202)
The Kubernetes Operator Framework Book by Michael Dame(8570)
Exploring Deepfakes by Bryan Lyon and Matt Tora(8407)
Robo-Advisor with Python by Aki Ranin(8361)